package com.example.demo.controller;

import com.example.demo.service.insertService;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;

import javax.annotation.Resource;

@Component
public class insertController {

    @Resource
    insertService is;

    @Scheduled(initialDelay = 1000, fixedRate = 10000)
    public void timings() {

        System.out.println("++++++++++++++");

        is.insertSql();

        System.out.println("--------------");

    }


}
